package com.huowenjie.service;

import com.huowenjie.dao.DeptDao;
import com.huowenjie.entity.Dept;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
public class DeptSeerviceImpl implements DeptService {

    @Autowired
    DeptDao deptDao;

    @Override
    public List<Dept> deptList() {
        List<Dept> depts = deptDao.findAll();
        return depts;
    }
}
